/*
 * QE3e Qt Quick 3D Engine.
 * Copyright (C) 2010 Joris Vaillant and Mathieu Pujol 
 * <joris.vaillant@gmail.com>  <mathieu.pujol87@gmail.com>
 * 
 * This library is free software; you can redistribute it and/or
 * modify it under the terms of the GNU Lesser General Public
 * License as published by the Free Software Foundation; either
 * version 2.1 of the License, or (at your option) any later version.
 * 
 * This library is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
 * Lesser General Public License for more details.
 * 
 * You should have received a copy of the GNU Lesser General Public
 * License along with this library; if not, write to the Free Software
 * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301  USA
 */


#ifndef ITEMFX_H
#define ITEMFX_H
//QE3E
#include <qe3e_global.h>
#include <qe3e_opengl.h>
#include <LightItem.h>

//Qt
#include <QList>
class QString;
class QVariant;

namespace qe3e
{
  class Item;


  typedef quint64 ITEM_FX_ID;//id sur 64bits

  class QE3E_EXPORT ItemFx
  {
  public:
    ItemFx();

    virtual ITEM_FX_ID getId() const;
    virtual void drawItem(const Item * item);
    virtual bool isHardwareSupported() const;
    virtual void setParameter(const QString & name,const QVariant & value);
    void setLights(const QList<LightDescriptor> & lights);

  protected:

    void drawItemFixedPipeline(const Item * item);

    bool mWireframe;
    bool mPoint;
    bool mLighting;
    bool mFlat;
    bool mShadow;
    bool mTexturing;
    bool mFixedPipeline;
    QList<LightDescriptor> mLights;

    int mFixedPipelineMaxLight;
  };
}

#endif // ITEMFX_H
